Paxos Made Practical
نویسنده
چکیده
Paxos [3] is a simple protocol that a group of machines in a distributed system can use to agree on a value proposed by a member of the group. If it terminates, the protocol reaches consensus even if the network was unreliable and multiple machines simultaneously tried to propose different values. The basic idea is that each proposal has a unique number. Higher numbered proposals override lower-numbered ones. However, a “proposer” machine must notify the group of its proposal number before proposing a particular value. If, after hearing from a majority of the group, the proposer learns one or more values from previous proposals, it must re-use the same value as the highest-numbered previous proposal. Otherwise, the proposer can select any value to propose. The protocol has three rounds. In the first round, the proposer selects a proposal number, n > 0. n’s low-order bits should contain a unique identifier for the proposer machine, so that two different machines never select the same n. The proposer then broadcasts the message prepare(n). Each group member either rejects this message if it has already seen a prepare message greater than n, replies with prepare-result(n, v) if the highest numbered proposal it has seen is n < n for value v, or replies with prepare-result(0,nil) if it has not yet seen any value proposed. If at least a majority of the group (including the proposer) accepts the prepare message, the proposer moves to the second round. It sets v to the value in the highest-numbered prepareresult it received. If v is nil, it selects any value it wishes for v. The proposer then broadcasts the message propose(n, v). Again, each group member rejects this message if it has seen a prepare(n) message with n > n. Otherwise, it indicates acceptance in its reply to the proposer.
منابع مشابه
PaxosStore: High-availability Storage Made Practical in WeChat
In this paper, we present PaxosStore, a high-availability storage system developed to support the comprehensive business of WeChat. It employs a combinational design in the storage layer to engage multiple storage engines constructed for different storage models. PaxosStore is characteristic of extracting the Paxos-based distributed consensus protocol as a middleware that is universally accessi...
متن کاملEmpirical Study of Unstable
This thesis studies the effect of unstable leaders in Paxos protocol. Paxos algorithm is one of the most popular solutions for distributed consensus, and is often used for building replicated state machines. Safety is guaranteed by Paxos algorithm regardless of various machine and communication failures. However, the liveness is compromised when multiple Paxos leaders exist at the same time. Al...
متن کاملIn Search of an Understandable Consensus Algorithm
Raft is a consensus algorithm for managing a replicated log. It produces a result equivalent to (multi-)Paxos, and it is as efficient as Paxos, but its structure is different from Paxos; this makes Raft more understandable than Paxos and also provides a better foundation for building practical systems. In order to enhance understandability, Raft separates the key elements of consensus, such as ...
متن کاملPractical Experience Report: The Performance of Paxos in the Cloud
This experience report presents the results of an extensive performance evaluation conducted using four opensource implementations of Paxos deployed in Amazon’s EC2. Paxos is a fundamental algorithm for building fault-tolerant services, at the core of state-machine replication. Implementations of Paxos are currently used in many prototypes and production systems in both academia and industry. A...
متن کاملTutorial Summary: Paxos Explained from Scratch
Paxos is a flexible and fault tolerant protocol for solving the consensus problem, where participants in a distributed system need to agree on a common value. However, Paxos is reputed for being difficult to understand. This tutorial aims to address this difficulty by visualizing Paxos in a completely new way. Starting from a naive solution and strong assumptions, Paxos is derived in a step-wis...
متن کامل